package com.nut.spp.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.nut.spp.entity.CouponWhite;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import org.springframework.web.bind.annotation.RequestParam;

@Mapper
public interface CouponWhiteMapper extends BaseMapper<CouponWhite> {

    @Select("select * from biz_coupon_white where mobile=#{mobile} and deleted=0 limit 1")
    CouponWhite selectByMobile(@RequestParam("mobile") String mobile);

    Page<CouponWhite> listPage(Page page, @Param("mobile") String mobile);

}
